import { AppCfg } from "../../AppCfgs";
import { GameCtx } from "../../GameCtx";
import { BaseData } from "./BaseData";

export class PlayerData extends BaseData{
    private constructor(){
        super()
    }
    private static _instance: PlayerData = null;
    public static get ins(): PlayerData {
        if (this._instance == null) {
            this._instance = new PlayerData();
        }
        return this._instance;
    }



    getDataKey(): string {
        return "PlayerData"
    }

    
    loadData(): void {
        if(GameCtx.ins.dataFrom==="local"){
            this.loadDataFromStorege();
            return
        }
        this.loadDataFromServer()
    }
    /**从远程拉取数据 */
    loadDataFromServer() {

    }
    /**从本地拉取数据 */
    loadDataFromStorege() {
    }
}